<!DOCTYPE html>
<html>
  <!--
      Copyright 2010 Google Inc. All Rights Reserved.

      Use of this source code is governed by an Apache 2.0 License.
      See the COPYING file for details.
    -->


  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
    <link href="users_guide.css" rel="stylesheet" type="text/css">

    <title>BidiChecker User's Guide</title>
  </head>

  <body>

    <table width="100%"><tr>
    <td class="prev-link" width="33%"><a href="overview.html">&lt;&lt; Overview &lt;&lt;</a></td>
    <td class="up-link" width="33%"><a href="index.html">
        ^^ Table of Contents ^^</a></td>
    <td class="next-link" width="33%"><a href="writing_regression_tests.html">&gt;&gt; Writing regression tests &gt;&gt;</a></td>
    </tr></table>

    <hr>

    <h1><a href="index.html">BidiChecker User's Guide</a></h1>

    <h2>2. Getting started</h2>

        <ul>
      <li><a href="#GettingBidiChecker">Getting BidiChecker</a></li>
      <li><a href="#PlatformSupport">Platform support</a></li>
    </ul>

    <h3><a name="GettingBidiChecker">Getting BidiChecker</a></h3>

    <p><b>Browser bookmarklet:</b> To install the bookmarklet in your
      browser's Bookmarks toolbar, go to the
      <a href="http://bidichecker.googlecode.com/svn/trunk/src/bookmarklet.html"
         target="_blank">BidiChecker
      Bookmarklet Installation Page</a>. You will find two links labeled
      "BidiChecker LTR" and "BidiChecker RTL". Dragging each of those links to
      your Bookmarks toolbar will install a button which, when clicked, runs
      BidiChecker on the page currently in the browser. The LTR bookmarklet
      expects the page to have a left-to-right UI; the RTL bookmarklet is for
      pages with a right-to-left UI.</p>

    <p><b>Source code:</b> The BidiChecker source code can be downloaded from
      <a href="http://code.google.com/p/bidichecker">http://code.google.com/p/bidichecker</a>
      using the following command:</p>

    <p><span class="inline-code">svn checkout
        http://bidichecker.googlecode.com/svn/trunk/ bidichecker</span></p>

    <p>Source code and unit tests can be found in the
      <a href="http://code.google.com/p/bidichecker/source/browse/#svn/trunk/src"><span class="inline-code">src/</span></a>
      subdirectory. This user's guide is in the
      <a href="http://code.google.com/p/bidichecker/source/browse/#svn/trunk/docs/users_guide"><span class="inline-code">docs/users_guide</span></a>
      subdirectory, with the complete API documentation in
      <a href="http://code.google.com/p/bidichecker/source/browse/#svn/trunk/docs/jsdoc"><span class="inline-code">docs/jsdoc/</span></a>.
      A sample application, along with demonstrations of how BidiChecker can be
      used to check for bidi errors, can be found in
      <a href="http://code.google.com/p/bidichecker/source/browse/#svn/trunk/samples/reviews"><span class="inline-code">samples/reviews/</span></a>.</p>

    <p>The
      <a href="http://code.google.com/p/bidichecker/source/browse/#svn/trunk/lib"><span class="inline-code">lib/</span></a>
      subdirectory contains a self-contained, deployable installation of
      BidiChecker. If you copy this directory to a web server, you can easily
      run BidiChecker either from automated unit tests or via the browser
      bookmarklet. The directory contains:
      <ol>
        <li>a single-file, precompiled version of BidiChecker, named
          <span class="inline-code">bidichecker_packaged.js</span>. Loading
      this one file from the web page to be tested is the usual way to use
      BidiChecker (you only need BidiChecker's source code if you want to
      modify BidiChecker or understand its internal workings). For an example of
      how to use the precompiled package, see
      <a href="http://code.google.com/p/bidichecker/source/browse/trunk/samples/reviews/reviews_packaged_test.html"><span class="inline-code">samples/reviews/reviews_packaged_test.html</span></a>.</li>
        <li>a local copy of the bookmarklet installation page (
          <span class="inline-code">bookmarklet.html</span> and
          <span class="inline-code">bookmarklet.css</span>). The bookmarklet
          links generated by this page will load Javascript files from the same
          installation directory, allowing you to easily run BidiChecker on a
          local web server.</li>
        <li>The BidiChecker GUI code, located in the
          <span class="inline-code">gui-app</span> subdirectory. This contains
          a precompiled file <span class="inline-code">gui_compiled.js</span>,
          the web pages which host the GUI, and their style file.</li>
      </ol>
      Note that the entire <span class="inline-code">lib/</span> subdirectory
      tree should be installed on a web server and accessed via
      <span class="inline-code">http:</span> or
      <span class="inline-code">https:</span>.
    </p>

    <p>BidiChecker source code uses the
      <a href="http://code.google.com/p/closure-library/">Closure Library</a>,
      an open-source library of useful Javascript modules. If you want to run
      a modified version of BidiChecker or run BidiChecker's own unit tests,
      you will need to install a copy of the Closure Library on your system.
      To do that, run the following command from the same working directory as
      you ran the above command:</p>

    <p><span class="inline-code">svn checkout
        http://closure-library.googlecode.com/svn/trunk/
        bidichecker/third_party/closure-library</span></p>

    <p>BidiChecker does not currently easily support linking with a copy of
      the Closure Library at a different location. Please note that you do
      <b>not</b> need to install the Closure Library to use the precompiled
      version of BidiChecker.</p>

    <p>For an example of how to use BidiChecker with the Closure Library,
      see
      <a href="http://code.google.com/p/bidichecker/source/browse/trunk/samples/reviews/reviews_closure_test.html"><span class="inline-code">samples/reviews/reviews_closure_test.html</span></a>.
    </p>

    <h3><a name="PlatformSupport">Platform support</a></h3>

    <p>The core BidiChecker backend Javascript code is regularly tested on
      a selection of browsers. The browser bookmarklet has been tested on
      Firefox and Chrome. It is not currently supported on Internet Explorer
      prior to version 9.
    </p>

    <p>Regardless, the bidi errors identified by the tool are not
      platform-specific; the code searches the DOM for errors, and it
      may find errors which only cause display garbling on browsers
      other than the one on which it is run. It should not be
      necessary to run the tool on a particular browser in order to
      find bidi errors for that browser.</p>




    <hr>

    <table width="100%"><tr>
    <td class="prev-link" width="33%"><a href="overview.html">&lt;&lt; Overview &lt;&lt;</a></td>
    <td class="up-link" width="33%"><a href="index.html">
        ^^ Table of Contents ^^</a></td>
    <td class="next-link" width="33%"><a href="writing_regression_tests.html">&gt;&gt; Writing regression tests &gt;&gt;</a></td>
    </tr></table>

  </body>
</html>
